<?php
return array(
    'extends' => 'http',
    
    'classes' => array(
        'wogu2\mvc\router\http\Query',
        'wogu2\mvc\router\http\Regex',
        'wogu2\mvc\router\http\Common',
        'wogu2\mvc\interceptor\http\Parameters',
    ),
    
    'objects' => array(
        'request'      => array(
            'class' => 'wogu2\http\Request',
            'config' => array(
                'appDir' => APP_DIR,
            ),
        ),
        'router.query' => array(
            'class' => 'wogu2\mvc\router\http\Query'
        ),
        'router.regex' => array(
            'class' => 'wogu2\mvc\router\http\Regex',
            'config' => array(
                'routerMap' => $config['routerMap'],
            ),
        ),
        'router.common' => array(
            'class' => 'wogu2\mvc\router\http\Common'
        ),
        'router'       => array(
            'class' => 'wogu2\mvc\router\RouterStack',
            'depends' => array(
                'routers' => 'router.query,router.regex,router.common',
            ),
        ),
        'response'     => 'wogu2\http\Response',
        'dispatcher'   => array(
            'class' => 'wogu2\mvc\Dispatcher',
            'depends'  => 'request',
            'objects' => array(
                'interceptors' => array(
                    'wogu2\mvc\interceptor\http\Parameters',
                ),
            ),
        ),
        'application'  => array(
            'class'    => 'wogu2\mvc\Application',
            'depends'  => 'request,router,response,dispatcher'
        ),
    ),
);
